﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace TB.BLL
{
    internal class DataProvider
    {
        private static TB.DALFactory.DALFactory instance = null;
        static DataProvider()
        {
            System.Reflection.Assembly dll = System.Reflection.Assembly.LoadFile(System.Web.HttpContext.Current.Server.MapPath("~/DataProviders/" + "TB.DALSqlProvider.dll"));
            instance = dll.CreateInstance("TB.DALSqlProvider.DALSqlFactory") as TB.DALFactory.DALFactory;
        }
        private DataProvider()
        {

        }
        public static TB.DALFactory.DALFactory DefaultProvider
        {
            get
            {
                return instance;
            }
        }
    }
}
